<?php

class Cat_Compiler extends Cat_ParamHolder
{		
	private $crawlers = array();
	
	function addCrawler( Cat_Crawler_Interface $p )
	{
		$p->setCompiler( $this );
		$this->crawlers[] = $p;
	}

	function getCrawlers()
	{
		return $this->crawlers;
	}
	
	function compile()
	{
		foreach( $this->getCrawlers() as $crawler )
		{
			$crawler->crawl();
		}
	}
}

?>